package com.haima.ziliao.service.impl;

import java.util.List;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;
import com.haima.ziliao.mapper.PJiajiaoMapper;
import com.haima.ziliao.domain.PJiajiao;
import com.haima.ziliao.service.IPJiajiaoService;
import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;

/**
 * 家教Service业务层处理
 * 
 * @author hima
 * @date 2024-12-05
 */
@Service
public class PJiajiaoServiceImpl extends ServiceImpl<PJiajiaoMapper, PJiajiao> implements IPJiajiaoService
{
    @Autowired
    private PJiajiaoMapper pJiajiaoMapper;

    /**
     * 查询家教
     * 
     * @param id 家教主键
     * @return 家教
     */
    @Override
    public PJiajiao selectPJiajiaoById(Long id)
    {
        return pJiajiaoMapper.selectPJiajiaoById(id);
    }

    /**
     * 查询家教列表
     * 
     * @param pJiajiao 家教
     * @return 家教
     */
    @Override
    public List<PJiajiao> selectPJiajiaoList(PJiajiao pJiajiao)
    {
        return pJiajiaoMapper.selectPJiajiaoList(pJiajiao);
    }

    /**
     * 新增家教
     * 
     * @param pJiajiao 家教
     * @return 结果
     */
    @Override
    public int insertPJiajiao(PJiajiao pJiajiao)
    {
        return pJiajiaoMapper.insertPJiajiao(pJiajiao);
    }

    /**
     * 修改家教
     * 
     * @param pJiajiao 家教
     * @return 结果
     */
    @Override
    public int updatePJiajiao(PJiajiao pJiajiao)
    {
        return pJiajiaoMapper.updatePJiajiao(pJiajiao);
    }

    /**
     * 批量删除家教
     * 
     * @param ids 需要删除的家教主键
     * @return 结果
     */
    @Override
    public int deletePJiajiaoByIds(Long[] ids)
    {
        return pJiajiaoMapper.deletePJiajiaoByIds(ids);
    }

    /**
     * 删除家教信息
     * 
     * @param id 家教主键
     * @return 结果
     */
    @Override
    public int deletePJiajiaoById(Long id)
    {
        return pJiajiaoMapper.deletePJiajiaoById(id);
    }
}
